Merged [21375] and [21376] - fixes to IKImagePickerForTiger [21372]
[adiumx.git] / Frameworks / AIUtilities Framework / Source / IKPictureTakerForTiger.h
blobffd477bdf21cc4a91a631dc775a057b186ff4d7d
1 //
2 // IKPictureTakerForTiger.h
3 // AIUtilities.framework
4 //
5 // Created by Evan Schoenberg on 10/28/07.
6 //
8 #import <Cocoa/Cocoa.h>
9 #import <Quartz/Quartz.h>
10 #import "AITigerCompatibility.h"
12 /* Define constants if building without them available */
13 #ifndef IKPictureTakerAllowsVideoCaptureKey
14 #define IKPictureTakerAllowsVideoCaptureKey @"IKPictureTakerAllowsVideoCaptureKey"
15 #define IKPictureTakerAllowsFileChoosingKey @"IKPictureTakerAllowsFileChoosingKey"
16 #define IKPictureTakerShowRecentPictureKey @"IKPictureTakerShowRecentPictureKey"
17 #define IKPictureTakerUpdateRecentPictureKey @"IKPictureTakerUpdateRecentPictureKey"
18 #define IKPictureTakerAllowsEditingKey @"IKPictureTakerAllowsEditingKey"
19 #define IKPictureTakerShowEffectsKey @"IKPictureTakerShowEffectsKey"
20 #define IKPictureTakerInformationalTextKey @"IKPictureTakerInformationalTextKey"
21 #define IKPictureTakerImageTransformsKey @"IKPictureTakerImageTransformsKey"
22 #define IKPictureTakerOutputImageMaxSizeKey @"IKPictureTakerOutputImageMaxSizeKey"
23 #define IKPictureTakerCropAreaSizeKey @"IKPictureTakerCropAreaSizeKey"
24 #define IKPictureTakerShowAddressBookPictureKey @"IKPictureTakerShowAddressBookPictureKey"
25 #define IKPictureTakerShowEmptyPictureKey @"IKPictureTakerShowEmptyPictureKey"
26 #endif
28 @interface IKPictureTakerForTiger : NSObject {
29 id pickerController;
30 id delegate;
31 SEL didEndSelector;
32 NSImage *inputImage;
33 NSImage *outputImage;
36 + (IKPictureTakerForTiger *) pictureTaker;
37 - (void) setInputImage:(NSImage *) image;
38 - (NSImage *)inputImage;
39 - (NSImage*) outputImage;
40 - (void)close;
41 - (void)setTitle:(NSString *)title;
43 * didEndSelector - (void)pictureTakerDidEnd:(IKPictureTakerForTiger *)pictureTaker returnCode:(NSInteger)returnCode contextInfo:(void *)contextInfo;
45 - (void) beginPictureTakerSheetForWindow:(NSWindow *)aWindow withDelegate:(id) delegate didEndSelector:(SEL) didEndSelector contextInfo:(void *) contextInfo;
47 - (void) beginPictureTakerWithDelegate:(id) delegate didEndSelector:(SEL) didEndSelector contextInfo:(void *) contextInfo;
50 IKPictureTakerAllowsVideoCaptureKey
51 A key for allowing video capture. The associated value is an NSNumber value (BOOL) whose default value is YES.
53 Available in Mac OS X v10.5 and later.
55 IKPictureTakerAllowsFileChoosingKey
56 A key for allowing the user to choose a file. The associated value is an NSNumber object that contains a BOOL value whose default value is YES.
58 Available in Mac OS X v10.5 and later.
60 IKPictureTakerUpdateRecentPictureKey
61 A key for allowing a recent picture to be updated. The associated value is an NSNumber object that contains a BOOL value whose default value is YES.
63 Available in Mac OS X v10.5 and later.
65 IKPictureTakerAllowsEditingKey
66 A key for allowing image editing. The associated value is an NSNumber object that contains a BOOL value whose default value is YES.
68 Available in Mac OS X v10.5 and later.
70 IKPictureTakerShowEffectsKey
71 A key for showing effects. The associated value is an NSNumber object that contains a BOOL value whose default value is NO.
73 Available in Mac OS X v10.5 and later.
75 IKPictureTakerInformationalTextKey
76 A key for informational text. The associated value is an NSString or NSAttributedString object whose default value is "Drag Image Here".
78 Available in Mac OS X v10.5 and later.
80 IKPictureTakerImageTransformsKey
81 A n image transformation key. The associated value is an NSDictionary object that can be serialized.
83 Available in Mac OS X v10.5 and later.
85 IKPictureTakerOutputImageMaxSizeKey
86 A key for the maximum size of the output image. The associated value is an NSValue object (NSSize).
88 Available in Mac OS X v10.5 and later.
90 IKPictureTakerCropAreaSizeKey
91 A key for the cropping area size. The associated value is an NSValue object (NSSize).
93 Available in Mac OS X v10.5 and later.
95 IKPictureTakerShowAddressBookPictureKey
96 A key for showing the address book picture. The associated value is a Boolean value packages as an NSNumber object. The default value is NO. If set to YES, the picture taker automatically adds the address book image for the Me user at the end of the Recent Pictures pop-up menu.
98 Available in Mac OS X v10.5 and later.
100 IKPictureTakerShowEmptyPictureKey
101 A key for showing an empty picture. The associated value is an NSImage object. The default value is nil. If set to an image, the picture taker automatically shows an image at the end of the Recent Pictures pop-up menu. that means "no picture."
103 Available in Mac OS X v10.5 and later.
105 @end
107 @interface NSObject (IKPictureTakerForTigerDelegate)
108 - (void)pictureTakerDidEnd:(id)inPictureTaker returnCode:(NSInteger)returnCode contextInfo:(void *)contextInfo;
109 @end